<?php 

$submenuStanice = "
	<div id=\"m1\" 
    	onmouseover=\"mcancelclosetime()\" 
		onmouseout=\"mclosetime()\">
		<a href=\"stanice.php?action=pretraga\">Pretraga stanica </a>
		<a href=\"stanice.php?action=new\">Nova stanica </a>
		<a href=\"stanice.php?action=atributi\"> Svojstva stanica </a>
	</div>
";

$submenuKemikalije ="
	<div id=\"m2\" 
    	onmouseover=\"mcancelclosetime()\" 
		onmouseout=\"mclosetime()\">
		<a href=\"kemikalije.php?action=pretraga\">Pretraga kemikalija </a>
		<a href=\"kemikalije.php?action=new\">Nova kemikalija </a>
		<a href=\"kemikalije.php?action=atributi\"> Svojstva kemikalija </a>
	</div>
";
//		<a href=\"kemikalije.php?action=atributi\"> Arhiva narudžbi </a>


$submenuRecepti = "
	<div id=\"m3\" 
    	onmouseover=\"mcancelclosetime()\" 
		onmouseout=\"mclosetime()\">
		<a href=\"recepti.php?action=pretraga\">Pretraga recepta </a>
		<a href=\"recepti.php?action=new\">Novi recept </a>
	</div>
";

$submenuMisevi = "
	<div id=\"m4\" 
    	onmouseover=\"mcancelclosetime()\" 
		onmouseout=\"mclosetime()\">
		<a href=\"misevi.php?action=pretraga\"> Pretraga miševa </a>
		<a href=\"misevi.php?action=new\">Novi miš</a>
		<a href=\"misevi.php?action=atributi\"> Svojstva miševa </a>
	</div>
";

$menuAdmin = "
	<li>
	<a href=\"admin.php\"
		    	onmouseover=\"mopen('m5')\" 
		        onmouseout=\"mclosetime()\"> 
		    	<img src=\"images/administracija.png\" width=\"36px\" height=\"36px\"><br>
		    	Administracija
	</a>
	<div id=\"m5\" 
    	onmouseover=\"mcancelclosetime()\" 
		onmouseout=\"mclosetime()\">
		<a href=\"admin.php?action=korisnici\">Korisnici</a>
		<a href=\"admin.php?action=postavke\">Postavke </a>
	</div>
	</li>
";

$isAdmin = isAdmin();
?>

<table width='100%'>
<tr>
	<td width="200" align="center"> 
		<img class='logo' src="/images/medriLogo.png"/>
	</td>
	
	<td>
		<ul id="izbornik">
		    <li>
		    	<a href="stanice.php" 
		        onmouseover="mopen('m1')" 
		        onmouseout="mclosetime()">
		        	<img src="images/stanice.png" width="36px" height="36px"><br>
		        	Stanice
		        </a>
		        <?php if ($isAdmin) print($submenuStanice); ?>
		    </li>
		    <li><a href="kemikalije.php" 
		        onmouseover="mopen('m2')" 
		        onmouseout="mclosetime()"> 
		        	<img src="images/kemikalije.png" width="36px" height="36px"><br>
		        	Kemikalije 
		        </a>
		        <?php if ($isAdmin) print($submenuKemikalije); ?>

		    </li>
		    <li><a href="recepti.php"
		    	onmouseover="mopen('m3')" 
		        onmouseout="mclosetime()"> 
		    	<img src="images/recepti.png" width="36px" height="36px"><br>
		    	Recepti 
		  		</a>
		        <?php if ($isAdmin) print($submenuRecepti); ?>

		    </li>
		    <li><a href="misevi.php"
		    	onmouseover="mopen('m4')" 
		        onmouseout="mclosetime()"> 
		    	<img src="images/misevi.png" width="36px" height="36px"><br>
		    	Miševi 
		    	</a>
		    	<?php if ($isAdmin) print($submenuMisevi); ?>
		    </li>
		    <?php if ($isAdmin) print($menuAdmin); ?>
		</ul>
		<div style="clear:both"></div>
	</td>

	<td width="150px" align="right" valign="top"> 
		<?php if (isUser()) print($logoutButton); ?>
	</td>
</tr>		
</table>


